/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package org.icosagon.core.items;


import org.icosagon.core.math.Equation;

/**
 *
 * @author Daniel Owens
 */
public class Weapon extends Equipment {

    private Equation damage;
    private Equation range;
    private String type;

    private boolean twohanded = false;
    private boolean melee = true;
    private int crit_mod = 0;
    private int crit_max = 20, crit_min = 20;

    public Equation getRange() {
        return range;
    }

    public void setRange(Equation range) {
        this.range = range;
    }

    public String getType() {
        return type;
    }

    public void setType(String type) {
        this.type = type;
    }

    public void setTwoHanded(boolean value) {
        this.twohanded = value;
    }

    public boolean isTwoHanded() {
        return this.twohanded;
    }

    public void setMelee(boolean value) {
        this.melee = value;
    }

    public boolean isMelee() {
        return this.melee;
    }

    public boolean isRanged() {
        boolean value = this.melee ? false : true;
        return value;
    }

    public void setDamage(Equation die) {
        this.damage = die;
    }

    public Equation getDamage() {
        return this.damage;
    }

    public void setCriticalHitModifier(int value) {
        this.crit_mod = value;
    }

    public int getCriticalHitModifier() {
        return this.crit_mod;
    }

    public void setMaxCriticalRoll(int value) {
        this.crit_max = value;
    }

    public int getMaxCriticalRoll() {
        return this.crit_max;
    }

    public void setMinCriticalRoll(int value) {
        this.crit_min = value;
    }

    public int getMinCriticalRoll() {
        return this.crit_min;
    }
}